package com.pink.mappers;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.pink.entity.dto.VideoFileDto;
import com.pink.entity.query.VideoFilesQuery;
import com.pink.entity.vo.request.VideoFileVo;
import com.pink.entity.vo.response.VideoFileLoadFileDataListVo;
import com.pink.entity.vo.response.VideoFilesVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface VideoFileMapper extends BaseMapper<VideoFileDto> {

    @Select("SELECT * FROM video_file left join video_info on video_file.video_id = video_info.video_id")
    List<VideoFileLoadFileDataListVo> findFileQueryList();

    @Select("SELECT * FROM video_file left join video_info on video_file.video_id = video_info.video_id where video_info.title like #{title}")
    List<VideoFileLoadFileDataListVo> findFileQueryList(String title);
}
